<template>
  <div class="search-form">
    <slot name="bossLogo"></slot>
    <div class="city-select" @click="showShelter">
      <b>全国</b>
      <span class="el-icon-caret-bottom"></span>
    </div>
    <div class="input-ele">
      <input type="text" placeholder="搜索职位、公司">
    </div>
    <slot name="searchBtn"></slot>
  </div>
</template>
<script>
export default {
  name: "searchform",
  data() {
    return {
      shelter: ""
    }
  },
  mounted() {
    this.shelter = document.querySelector(".shelter");
    this.searchEle = document.querySelector(".search-form");
  },
  methods: {
   showShelter(){
    this.shelter.style.display = "block";
   }
  },
}
</script>
<style lang="less">
  .search-form{
    display: flex;
    justify-content: center;
    align-items: center;
    border: 1px solid transparent;
      .city-select{
        width: 110px;
        height: 50px;
        background-color: #fff;
        text-align: center;
        line-height: 50px;
        border-right: 1px solid #ccc;
        flex-shrink: 0;
        cursor: pointer;
          span{
            margin-left: 20px;
            color: #9fa3b0;
          }
  }
      .input-ele{
        height: 50px;
        width: 685px;
        background-color: #66a;
          input{
            border: 0;
            outline: none;
            width: 685px;
            height: 48px;
            text-indent: 20px;
          }
      }
      .search{
        width: 140px;
        height: 50px;
        background-color: #5dd5c8;
        border: none;
        cursor: pointer;
        color: #fff;
        flex-shrink: 0;
          &:hover{
            background-color: #6adbcf;
          }
      }
  }  
</style>